package com.soaptesting;

import com.soaptesting.jaxws.GetMsgs;
import com.soaptesting.jaxws.GetMsgsResponse;
import com.soaptesting.jaxws.SaveMsg;
import com.soaptesting.jaxws.SaveMsgResponse;

public class MsgManagerAdapter {

	private MsgManager msgMgr = new MsgManager();
	
	public SaveMsgResponse saveMsg(SaveMsg request)
	{
		String location = request.getArg0();
		String msg = request.getArg1();
		SaveMsgResponse response = new SaveMsgResponse();
		response.setReturn(msgMgr.saveMsg(location, msg));
		return response;
	}
	
	public GetMsgsResponse getMsgs(GetMsgs request)
	{
		String location = request.getArg0();
		GetMsgsResponse response = new GetMsgsResponse();
		response.setReturn(msgMgr.getMsgs(location));
		return response;
	}
}
